﻿using System;

namespace TXLooker.WorkItemExtention.Core
{
    public class ColumnInfo:IComparable
    {
        public String ReferenceName { get; set; }
        
        public String ColumnHeaderText{ get; set;}

        public String Width { get; set; }


        public ColumnInfo(String referenceName, String columnHeaderText, String width)
        {
            ReferenceName = referenceName;
            ColumnHeaderText = columnHeaderText;
            Width = width;
        }

        public ColumnInfo()
        {}


        public int CompareTo(object obj)
        {
            if (obj is ColumnInfo)
            {
                var temp = (ColumnInfo)obj;

                return ColumnHeaderText.CompareTo(temp.ColumnHeaderText);
            }

            throw new ArgumentException("object is not a Content");
        }
    }
}
